package cn.mldn.mldncloud.service;

import cn.mldn.mldncloud.dto.RidersDTO;
import cn.mldn.mldncloud.service.config.FeignClientConfig;
import cn.mldn.mldncloud.service.fallback.RidersServiceFallbackFactory;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.List;

@FeignClient(value = "MLDNCLOUD-ZUUL-GATEWAY", configuration = FeignClientConfig.class,fallbackFactory=RidersServiceFallbackFactory.class)
public interface IRidersService {

    @GetMapping("/mldn-proxy/admin-proxy/riders/get/{riderId}")
     RidersDTO get(@PathVariable("riderId") long riderId);    // 根据部门编号获取部门信息

    @GetMapping("/mldn-proxy/admin-proxy/riders/list")
    public List<RidersDTO> list();                                // 部门信息列表
}
